/**
 * Program   :   ICodeAssistantService.java
 * Author    :   shadow guo
 * Create    :   2013-6-19 下午2:19:17
 *
 * Copyright 2008 by Tongfu Information Technology Co. Ltd
 * All rights reserved.
 *
 * This software is the confidential and proprietary information
 * of Tongfu Information Technology Co. Ltd. ("Confidential Information").  You
 * shall not disclose such Confidential Information and shall use
 * it only in accordance with the terms of the license agreement
 * you entered into with Tongfu Information Technology Co. Ltd.
 * 
 */
package com.tongfusoft.web.core.service.codeassistant;

import java.util.List;
import java.util.Map;

public interface ICodeAssistantService {
	/**
	 * 解析SQL，分解成select、from、where、group、orderby,columns
	 * @param sql
	 * @return
	 */
	public Map<String,Object> parserSQL(String sql);
	
	/**
	 * 获取List的Yaml
	 * @param jsonStr
	 * @return
	 */
	public String genListYaml(String jsonStr);
	
	/**
	 * 获取JqGrid的基本代码
	 * @param jsonStr
	 * @return
	 */
	public String genJqGrid(String jsonStr);
	
	/**
	 * 获取数据库中所有表
	 * @param dbId
	 * @return
	 */
	public List<Map<String,String>> getAllTable(String dbId);
	
	public Map<String,String> genBeanCode(String dbId,String tableName);
}
